/*******************************************************************************
 * Copyright (c) 2008, 2009 Tapestry IDE Developers
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 * 
 * Contributors:
 *     Tapestry IDE Developers - initial API and implementation
 *******************************************************************************/
package com.googlecode.tapestry.ide.core.model;

import java.util.Set;

import org.eclipse.core.resources.IProject;

/**
 * The Interface ITapestryModel.
 */
public interface ITapestryModel extends IModel {

	/** The model name. */
	String ELEMENT_NAME = "TapestryModel";

	/**
	 * Returns <code>true</code> if the given project is a Tapestry project.
	 * 
	 * @param project
	 *            the project
	 * 
	 * @return true, if checks for project
	 */
	boolean hasProject(IProject project);

	/**
	 * Returns the {@link ITapestryProject} for the given project or
	 * <code>null</code> if given project is not a Tapestry project.
	 * 
	 * @param project
	 *            the project
	 * 
	 * @return the project
	 */
	ITapestryProject getProject(IProject project);

	/**
	 * Returns a list of all projects defined in this model.
	 * 
	 * @return the projects
	 */
	Set<ITapestryProject> getProjects();

}
